<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>创建虚拟 DOM 对象 - JSX</title>
</head>
<body>
    <div id="root"></div>

    <script src="../js/react.development.js"></script>
    <script src="../js/react-dom.development.js"></script>
    <script src="../js/babel.min.js"></script>

    <script type="text/babel">
        //1. jsx 创建虚拟DOM
        // let vDOM = <div>我是一个 DIV 哦</div>;
        let vDOM = <div>
                <h2>初心印记｜“1731”克月壤的特殊意义</h2>
                <p>2020年12月17日凌晨1时59分，嫦娥五号返回器携带月球样品在内蒙古</p>
            </div>;

        //2. 将虚拟 DOM 对象, 创建为真实 DOM 插入到文档中
        ReactDOM.render(vDOM, document.querySelector('#root'));
    </script>
</body>
</html>